﻿namespace IceDog.DNL.CSharp.DesignPattern.ServiceLocatorPattern.Member
{
    public class MemberContext
    {
        public IMemberService Lookup(MemberServiceType serviceName)
        {
            switch (serviceName)
            {
                case MemberServiceType.TeacherSercie:
                    return new TeacherService();
                case MemberServiceType.StudentService:
                    return new StudentService();
                default:
                    return null;
            }
        }
    }
}
